using System;
using NUnit.Framework;
using Castle.ActiveRecord;
using NHibernate;
using Rhino.Mocks;

namespace DecisionesInteligentes.iEvalua.Tests.Models
{
	public class ActiveRecordMockTestCase<T> {
		
		protected MockRepository mocks;
		protected ISession session;
		
		[TestFixtureSetUp]
		public virtual void TestFixtureSetUp()
		{
			Boot.Initialize();
		}
		
		[SetUp]
		public virtual void SetUp()
		{
			mocks = new MockRepository();
			session = mocks.CreateMock<ISession>();
		}

		[TearDown]
		public virtual void TearDown()
		{
			if (mocks != null)
				mocks.VerifyAll();
		}
	}
}